fix(ci): auto-derive PGXN version from git tag#50
Conversation
META.json version was hardcoded at 0.1.7 and never updated, causing the v0.3.1 PGXN release to fail with "already exists". Update to 0.3.1 and add a workflow step that rewrites META.json version from the git tag before bundling, so future releases don't need manual bumps.
|
|
There was a problem hiding this comment.
Pull request overview
This PR automates the PGXN release process by deriving the version number from git tags, preventing the need for manual version bumps in META.json for each release. The PR also updates the static version in META.json to resolve a release conflict.
Changes:
- Update
META.jsonwith new version numbers to resolve the failed PGXN release - Add a GitHub Actions workflow step that automatically rewrites
META.jsonversion from git tags during release automation
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| META.json | Updates version fields from 0.1.7 to 0.3.2 in two locations (root and provides section) |
| .github/workflows/pgxn.yml | Adds a workflow step that extracts version from git tags and rewrites META.json before bundling for PGXN release |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| "docfile": "README.md", | ||
| "file": "pg_stat_ch.control", | ||
| "version": "0.1.7" | ||
| "version": "0.3.2" |
There was a problem hiding this comment.
The PR description states the version should be updated to "0.3.1" to address the failed v0.3.1 PGXN release, but the actual changes update META.json to "0.3.2" instead. This discrepancy should be clarified - either the description is incorrect or the version numbers in META.json should be 0.3.1.
Summary
META.jsonversion from stale0.1.7to0.3.1META.jsonversion from the git tag beforepgxn-bundle, so future releases don't require manual version bumpsContext
The v0.3.1 PGXN release failed with
Distribution "pg_stat_ch 0.1.7" already existsbecauseMETA.jsonwas never updated after its initial creation. The v0.3.0 release had already published 0.1.7.Test plan
v0.3.2) to trigger the PGXN workflow